<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8" %>




<form name=form1 method="post" target='_blank' action='result.jsp'>


<input type='hidden' name='optype' >


sql  <br>
<textarea name='sql' cols='120' rows='9'> </textarea>

<br>params <br>
<textarea name='params' cols='120' rows='3'> </textarea>

<br>

<input type='text' name='maxRows' value='200' style='width:50px'>

<input class='btn' type="button" value='query' onclick='query()'> 
           
<input class='btn' type="button"  value='update' onclick='update()'> 
           
</form>


<script>

 function query(){
	 form1.optype.value="query";
	 // form1.action='result.jsp';
	 form1.submit();
 }
 
 
 function update(){	 
	 var msg = "确认要执行更新操作?sql="+form1.sql.value;
	 if(!confirm(msg)){
		 return;
	 }
	 form1.optype.value="update";

	 form1.submit();
 }
 

</script>
